<template>
	<view>
		<u-card padding="16" v-for="(item,index) in dataList" :key="index">
			<view class="" slot="head">
				<view class="wrap">
					<u-row>
						<u-col span="12" text-align="center">
							<view class="u-line-1 u-m-t-2 weikaishi2">
								<span>{{item.warehouseName+item.areaName+'-'+item.positionNumber}}</span>
							</view>
						</u-col>
					</u-row>
					<u-row>
						<u-col span="6" text-align="center">
							<view class="u-line-1 u-m-t-4 weikaishi3">
								<span>库存数：{{item.num}}件</span>
							</view>
						</u-col>
						<u-col span="6" text-align="center">
							<view class="u-line-1 u-m-t-4 weikaishi3">
								<span>盘点数：{{item.trueNum}}件</span>
							</view>
						</u-col>
					</u-row>
				</view>
			</view>
			<view class="" slot="body">
				<view class="wrap" v-for="(item1,index1) in item.list" :key="index1">
					<u-row>
						<u-col span="12" text-align="left">
							<view class="u-m-t-4 weikaishi3 yiwancheng">
								<span>{{item1.goodsName}},{{item1.goodsNo}}</span>
							</view>
						</u-col>
					</u-row>
					<u-row>
						<u-col span="6" text-align="left">
							<view class="u-line-1 u-m-t-4">
								<span>库存数：{{item1.num}}件</span>
							</view>
						</u-col>
						<u-col span="6" text-align="fight">
							<view class="u-line-1 u-m-t-4 lanse">
								<span>盘点数：{{item1.trueNum}}件</span>
							</view>
						</u-col>
					</u-row>
					<u-collapse>
						<u-collapse-item title="详情">
							<u-row v-for="(item2,index2) in item1.list" :key="index2">
								<u-col span="6" text-align="left">
									<view class="u-line-1 u-m-t-4 weikaishi">
										<span>托盘：{{item2.trayNumber}}</span>
									</view>
								</u-col>
								<u-col span="6" text-align="left">
									<view class="u-line-1 u-m-t-4 weikaishi">
										<span>类型：{{item2.panType}}</span>
									</view>
								</u-col>
								<u-col span="5" text-align="left">
									<view class=" u-m-t-4">
										<span>库存数：{{item2.num}}</span>
									</view>
								</u-col>
								<u-col span="7" text-align="left">
									<view class=" u-m-t-4 lanse">
										<span>盘点数：{{item2.trueNum}}</span>
									</view>
								</u-col>
								<u-col span="5" text-align="left">
									<view class=" u-m-t-4">
										<span>批次：{{item2.goodsbatchs}}</span>
									</view>
								</u-col>
								<u-col span="7" text-align="left">
									<view class=" u-m-t-4 lanse">
										<span>盘点：{{item2.newgoodsbatchs}}</span>
									</view>
								</u-col>
								<u-col span="5" text-align="left">
									<view class="u-m-t-4">
										<span>创建人：{{item2.createUsername}}</span>
									</view>
								</u-col>
								<u-col span="7" text-align="left">
									<view class="u-m-t-4 lanse">
										<span>创建时间：{{item2.createTime}}</span>
									</view>
								</u-col>
								<u-col span="5" text-align="left" v-if="item2.dealPerson">
									<view class=" u-m-t-4">
										<span>处理人：{{item2.dealPerson}}</span>
									</view>
								</u-col>
								<u-col span="7" text-align="left" v-if="item2.dealTime">
									<view class="u-m-t-4 lanse">
										<span>处理时间：{{item2.dealTime}}</span>
									</view>
								</u-col>
								<u-col span="12" text-align="left" v-if="item2.dealTime">
									<view class=" u-m-t-20">
										<span>描述：{{item2.nodes}}</span>
									</view>
								</u-col>
							</u-row>
						</u-collapse-item>
					</u-collapse>
				</view>
			</view>
		</u-card>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				dataList:[],
			};
		},
		onLoad(open) {
			this.$http.post('/rest/ChouPan/findByGoodsList',{
			},{
				params: {
					diskId:open.diskId
				},
				header: {
					'Authorization' :uni.getStorageSync('token'),
				}
			}).then(res => {
				this.dataList = res.data.data
			})
		},
	}
</script>


<style lang="scss">
	.u-body-item {
		padding: 20rpx 15rpx;
	}
	.wrap {
		padding: 0rpx 12rpx;
	}

	.u-row {
		margin: 10rpx 2rpx;
	}

	.demo-layout {
		height: 40rpx;
		border-radius: 8rpx;
		line-height: 40rpx;
	}
	.demo-layout2 {
		height: 140rpx;
		border-radius: 8rpx;
	}
	.demo-layout3 {
		height: 900rpx;
		border-radius: 8rpx;
	}

	.bg-purple {
		background: #ffffff;
	}

	.bg-purple-light {
		background: #e5e9f2;
	}

	.bg-purple-dark {
		background: #99a9bf;
	}
	.weikaishi2{
		font-size: 36rpx;
	}
	.weikaishi3{
		font-size: 30rpx;
	}
</style>
